package vns.client.event;

import com.google.gwt.event.shared.GwtEvent;

public class RuleConditionEvent extends GwtEvent<RuleConditionEventHandler> {

	public static Type<RuleConditionEventHandler> TYPE = new Type<RuleConditionEventHandler>();
	private String ruleID = null;

	public RuleConditionEvent(String ruleID) {
		this.setRuleID(ruleID);
	}

	@Override
	public Type<RuleConditionEventHandler> getAssociatedType() {
		return TYPE;
	}

	@Override
	protected void dispatch(RuleConditionEventHandler handler) {
		handler.onRuleCondition(this);
	}

	public void setRuleID(String ruleID) {
		this.ruleID = ruleID;
	}

	public String getRuleID() {
		return ruleID;
	}
}
